package com.custom.view;

import com.custom.R;

import android.content.Context;
import android.content.res.TypedArray;
import android.util.AttributeSet;
import android.widget.CompoundButton;
import android.widget.RadioButton;

public class MRadioButton extends RadioButton implements
		RadioButton.OnCheckedChangeListener {
	private String mValue;

	public MRadioButton(Context context) {
		super(context);
	}

	public MRadioButton(Context context, AttributeSet attrs, int defStyle) {
		super(context, attrs, defStyle);
	}

	public MRadioButton(Context context, AttributeSet attrs) {
		super(context, attrs);

		TypedArray typedArray = context.obtainStyledAttributes(attrs,
				R.styleable.MRadioButton);
		this.mValue = typedArray.getString(R.styleable.MRadioButton_value);
		this.invalidate();
		typedArray.recycle();
		setOnCheckedChangeListener(this);
	}

	public String getValue() {
		return this.mValue;
	}

	public void setValue(String value) {
		this.mValue = value;
	}

	@Override
	public void onCheckedChanged(CompoundButton buttonView, boolean isChecked) {
		
	}

}
